package com.dullwolf;

import com.las.annotation.BotRun;
import com.las.core.Bot;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import redis.clients.jedis.JedisPoolConfig;

/**
 * 启动入口
 *
 * @author dullwolf
 */
@BotRun(superQQ = "1091569752",
        botQQ = "2547170055",
        keyAuth = "dw0123456789",
        miRaiUrl = "http://43.132.146.198:8080")
public class App {

    private static Logger logger = LoggerFactory.getLogger(App.class);

    public static void main(String[] args) {
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");
        JedisPoolConfig poolConfig = (JedisPoolConfig) context.getBean("poolConfig");
        if (null != poolConfig) {
            logger.info("spring-redis配置正常");
            Bot.run(App.class);
        }
    }
}